import requests
import os,json
from goods_feedback.config.setting import *
from goods_feedback.public.get_yaml import doYaml
from goods_feedback.public.header import *
from goods_feedback.public.getlogging import Logger
#from goods_feedback.handle.userquestion_search import user_questions_search
from goods_feedback.handle.questions_list import question_list

#filename=os.path.basename(__file__)  #获取对应路径下的文件名称
#logging=Logger(filename).getlog()

search=question_list()
id=search['rows'][0]['id']
print(id)
rs=doYaml.get_data(os.path.join(data_path,'questions_handle.yaml'))
base_url='{0}{1}{2}'.format(url,rs['path'],id)
method=rs['method']
payload={}
headers=form_headers

def question_handle():
    re=requests.request(method,base_url,headers=headers,data=payload).json()
    #print(re)
    return re

#question_handle()
